<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html" />
<title>closure set</title>

<script type="text/javascript" src="../jquery.js"></script>
<script type="text/javascript" src="../jquery.tools.min.js"></script>
<script type="text/javascript" src="../math/rect2d.js"></script>
<script type="text/javascript" src="../math/vector2d.js"></script>
<script type="text/javascript" src="../math/point2d.js"></script>
<script type="text/javascript">
    var r1 = mix.rect2d.create( 10, 10, 100, 100);
    console.log( "%d %d %d %d", r1.x, r1.y, r1.w, r1.h);
    var r2 = mix.rect2d.create( 80, 80, 50, 50);
    var r3 = mix.rect2d.interArea( r1, r2);
    console.log( "%d %d %d %d", r3.x, r3.y, r3.w, r3.h);
    
    var p1 = mix.point2d.create( 3, 4);
    var p2 = mix.point2d.create( 10, 10);
    console.log( "%f", mix.point2d.length( p1, p2));
    
    var v1 = mix.vector2d.create( 1, 1);
    var v2 = mix.vector2d.create( 1, 10);
    var v = mix.vector2d.lerp( v1, v2, 0.5);
    console.log( "%f", v.x, v.y);
</script>
<body>
</body>
</html>